home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The X-Philes (2nd Revision)
/
The X-Philes Number 1 (1995).iso
/
xphiles
/
hp48_1
/
pubdom.tar
/
pubdom
/
rbj
/
lll
< prev
next >
Wrap
Text File
|
1990-05-17
|
2KB
|
72 lines
%%HP: T(3)A(D)F(.);
@ LLL -- From BBS
@ (Comp.sys.handhelds) Main: r 227
@ Item: 227 by rsteele at XN.LL.MIT.EDU
@ Author: [Rob Steele]
@ Subj: HP-48 Movie
@ Date: Fri Mar 16 1990 07:52
@
@ The following code plots a series of lissajous and animates them.
@ It is possible to see the resulting figure in about eleventy-
@ two different ways: cylindrical or flat, rotating or oscillating
@ about a horizontal or vertical axis, moving toward you or
@ away, moving to the left or to the right, or just wobbling.
@
@ I call the program LLL for Lincoln Lab Lissajous since the lissajous
@ is our logo. To work it, download or enter it and press the GEN
@ button. It will run for a few minutes and beep when it's through.
@ Then press the SHO button and watch. Finally, press any key to quit.
@
@ If you have trouble seeing the image in different ways, try focusing
@ on a single intersection in the plot as it moves. Pretend that the
@ point is in front as it moves in one direction and in back when it
@ goes the opposite way. Once you get that to work, reverse directions.
@
@ Rob Steele
@ rsteele@xn.ll.mit.edu
@
DIR
GEN \<<
@ Generates a list of graphic objects and
@ stores them in IMAGES.
RCLF DEG
0 'IMAGES' STO
30 90 FOR i
i 'Z' STO
ERASE DRAW PICT RCL
10 STEP
7 \->LIST 'IMAGES' STO
STOF
1250 1 BEEP
\>>
SHO \<<
@ Displays the graphic objects in IMAGES
@ in rapid succession.
IMAGES SIZE \-> n
\<<
ERASE { # 0h # 0h } PVIEW
MEM DROP
WHILE KEY NOT REPEAT
1 n 1 - FOR i
PICT { # 0h # 0h } 'IMAGES' i GET REPL
NEXT
n 2 FOR i
PICT { # 0h # 0h } 'IMAGES' i GET REPL
-1 STEP
END
DROP
\>>
\>>
@ Definition of the lissajous.
@ Set Z to zero to produce the Lincoln logo.
EQ 'SIN(4*x+Z)+COS(3*x)*i'
Z 0
PPAR { (-3,-1) (3,1) { x 0 360 } 0 (10,10) PARAMETRIC Y }
IMAGES 0
END